package com.quick.service;

import com.quick.domain.IntelligentAssistantActionEnum;
import com.quick.domain.Order;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @ClassName OrderService
 * @Description TODO
 * @Author jojo.wang
 * @Date 2019-05-24 21:56
 * @Version 1.0
 **/
@Service
public class OrderService {
    @Resource
    private ActionHandleService actionHandleService;
    public String haveOrderType(Order order) throws Exception{
        IntelligentAssistantActionEnum intelligentAssistantActionEnum = IntelligentAssistantActionEnum.getValue(order.getType());
        String serviceName = intelligentAssistantActionEnum.getServiceName();
        Object o = actionHandleService.handler(serviceName,order,"testParam");
        return o.toString();
    }
}
